package com.whzykj.model;

import com.jfinal.plugin.activerecord.Model;
import com.whzykj.common.Consts;
import com.whzykj.jfinal.TableBind;

@TableBind(name="shopping",pk="id")
public class Shopping extends Model<Shopping>{
	private static final long serialVersionUID = 1L;
	public static final Shopping me=new Shopping();
	
	//查询商品在购籀车中是否存在
	public Shopping getShopp(String goodsid,String userid)
	{
	   String sql=" select * from shopping where goods_id=? and user_id= ? and status="+Consts.TRUE+" ";
	   return Shopping.me.findFirst(sql, goodsid,userid);
	}
	
}
